package com.maila.xiaoaoschool.activity;

import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.TextView;

import com.maila.xiaoaoschool.R;
import com.maila.xiaoaoschool.adapter.AffirmOrderAdapter;
import com.maila.xiaoaoschool.util.StartActivityUtils;
import com.maila.xiaoaoschool.widget.NoScrollListView;
import com.zhy.autolayout.AutoLinearLayout;
import com.zhy.autolayout.AutoRelativeLayout;

import butterknife.BindView;
import butterknife.ButterKnife;
import butterknife.OnClick;

/**
 * Created by Administrator on 2017/9/29.
 */

public class AffirmOrderActivity extends AppCompatActivity {
    @BindView(R.id.white_return_iv)
    AutoRelativeLayout whiteReturnIv;
    @BindView(R.id.tv_shop_namee)
    TextView tvShopNamee;
    @BindView(R.id.ll_title)
    AutoLinearLayout llTitle;
    @BindView(R.id.iv_song1)
    ImageView ivSong1;
    @BindView(R.id.tv_address)
    TextView tvAddress;
    @BindView(R.id.tv_name)
    TextView tvName;
    @BindView(R.id.ll_choose_address)
    AutoRelativeLayout llChooseAddress;
    @BindView(R.id.store_tv)
    TextView storeTv;
    @BindView(R.id.lv_goods)
    NoScrollListView lvGoods;
    @BindView(R.id.textView)
    TextView textView;
    @BindView(R.id.tv_canhe_fee)
    TextView tvCanheFee;
    @BindView(R.id.tv_trans_fee)
    TextView tvTransFee;
    @BindView(R.id.tv_shop_youhui)
    TextView tvShopYouhui;
    @BindView(R.id.goto_youhuilist)
    ImageView gotoYouhuilist;
    @BindView(R.id.default_youhui)
    TextView defaultYouhui;
    @BindView(R.id.rl_bouns_show)
    AutoRelativeLayout rlBounsShow;
    @BindView(R.id.guestbook_et)
    EditText guestbookEt;
    @BindView(R.id.total_youhui)
    TextView totalYouhui;
    @BindView(R.id.total_price)
    TextView totalPrice;
    @BindView(R.id.submit_order_btn)
    Button submitOrderBtn;
    AffirmOrderAdapter affirmOrderAdapter;

    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_affirm_order);
        ButterKnife.bind(this);
        affirmOrderAdapter=new AffirmOrderAdapter(this);
        lvGoods.setAdapter(affirmOrderAdapter);
    }

    @OnClick({R.id.white_return_iv, R.id.ll_choose_address, R.id.rl_bouns_show, R.id.submit_order_btn})
    public void onViewClicked(View view) {
        switch (view.getId()) {
            case R.id.white_return_iv:
                finish();
                break;
            case R.id.ll_choose_address:
                StartActivityUtils.start(this,MyAddressActivity.class);
                break;
            case R.id.rl_bouns_show:
                break;
            case R.id.submit_order_btn:
                StartActivityUtils.start(this,PayActivity.class);
                finish();
                break;
        }
    }
}
